package com.heima.comment.entity;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;
import org.bson.types.ObjectId;
import org.springframework.data.mongodb.core.mapping.Document;

import java.util.Date;

/**
 * @Author WSJ
 * @Date 2022-03-29-9:23
 * @Version 1.0 （版本号）
 */
@Data
@Document("ap_comment")
public class ApComment {
    private static final long serialVersionUID = 1L;
    /**
     * 评论id
     */
    @JsonSerialize(using = ToStringSerializer.class)
    private  ObjectId id;
    /**
     * 作者id
     */
    private  Integer authorId;
    /**
     * 作者名
     */
    private  String authorName;
    /**
     * 行为实体id
     */
    private  Long entryId;
    /**
     * 类型 评论 0
     */
    private  Integer type;
    /**
     * 内容
     */
    private  String content;
    /**
     * 评论人头像地址
     */
    private  String image;
    /**
     * 点赞数
     */
    private  Long likes;
    private  Integer reply;
    private  Integer flag;
    private  Date createdTime;
}
